﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using XVUEfxSDK.Xsequencer;

namespace SamplesCSharp.Simple
{
    public class HelloWorldText:ISampleBase
    {
        public override string ToString()
        {
            return "Simple Hello world";
        }

        IXvueSequencerUser sequencer;
        #region ISampleBase Members

        public void SetSequencer(IXvueSequencerUser seq)
        {
            sequencer = seq;
        }

        public void HelperDoAction(int actionnumber)
        {
            switch (actionnumber)
            {
                    //simple text show with clear all
                default:
                    {
                        sequencer.xCommand("XVUE", XvueSequencerCommandType.ClearAllItems);
                        XvueSequencerItemTextBase text = new XvueSequencerItemTextBase();
                        text.xText = "Hello world";
                        text.xFontFamily = "Arial";
                        text.xSize = 35;
                        text.xVisualProperties.xPosition.X = 100;
                        text.xVisualProperties.xPosition.Y = 300;
                        text.xPalette.ColorForeground = Color.FromArgb(255, 250, 250, 200);
                        sequencer.xQueSequencerItem(text);
                    } break;
            }
        }

        #endregion
    }
}
